//
//  YTMineCell.m
//  CllForIOS
//
//  Created by qiyun on 2018/3/8.
//  Copyright © 2018年 aRui. All rights reserved.
//

#import "YTMineCell.h"
@interface YTMineCell ()
@property (nonatomic, weak) UIImageView *icon;
@property (nonatomic, weak) UILabel *title;

@end
@implementation YTMineCell
- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    if (self = [super initWithStyle:style reuseIdentifier:reuseIdentifier]) {
        [self makeUI];
    }
    return self;
}

- (void)makeUI{
    UIImageView *icon = [[UIImageView alloc]initWithImage:IMAGE(@"Midcellicon2")];
    icon.contentMode=UIViewContentModeScaleAspectFit;
    [self.contentView addSubview:icon];
    self.icon = icon;
    //
    UILabel *title =[[UILabel alloc]init];
    title.textColor=[UIColor blackColor];
    title.font=KFONT(15);
    title.text=@"足球比分直播";
    [self.contentView addSubview:title];
    self.title = title;
}
-(void)layoutSubviews{
    [super layoutSubviews];
    
    self.icon.frame=CGRectMake(17, 22, 22, 22);
    CGPoint center= self.icon.center;
    center.y=self.contentView.frame.size.height/2;
    self.icon.center=center;
    
    self.title.frame=CGRectMake(58, 22, 80, 15);
    CGPoint titlecenter= self.title.center;
    titlecenter.y=self.contentView.frame.size.height/2;
    self.title.center=titlecenter;
    
}
@end
